﻿CREATE TABLE [dbo].[TabelaPrecoPublicidade] (
    [Id]                  INT            IDENTITY (1, 1) NOT NULL,
    [IdPacotePublicidade] INT            NOT NULL,
    [IdPeriodo]           INT            NOT NULL,
    [IdLocalBanner]       INT            NOT NULL,
    [Valor]               DECIMAL (6, 2) NOT NULL,
    [Ativo]               BIT            DEFAULT ('1') NOT NULL,
    PRIMARY KEY CLUSTERED ([Id] ASC) WITH (ALLOW_PAGE_LOCKS = ON, ALLOW_ROW_LOCKS = ON, PAD_INDEX = OFF, IGNORE_DUP_KEY = OFF, STATISTICS_NORECOMPUTE = OFF),
    FOREIGN KEY ([IdPeriodo]) REFERENCES [dbo].[Periodo] ([Id]) ON DELETE NO ACTION ON UPDATE NO ACTION,
    FOREIGN KEY ([IdLocalBanner]) REFERENCES [dbo].[LocalBanner] ([Id]) ON DELETE NO ACTION ON UPDATE NO ACTION,
    FOREIGN KEY ([IdPacotePublicidade]) REFERENCES [dbo].[PacotePublicidade] ([Id]) ON DELETE NO ACTION ON UPDATE NO ACTION
);



